export default class Api {

  static getChartDatas() {
    return new Promise((resolve, reject) => {
			let rawData = [
				['00:00', 2320.26, 2320.26, 2287.3, 2362.94],
				['01:00', 2300, 2291.3, 2288.26, 2308.38],
				['02:00', 2295.35, 2346.5, 2295.35, 2346.92],
				['03:00', 2347.22, 2358.98, 2337.35, 2363.8],
				['04:00', 2360.75, 2382.48, 2347.89, 2383.76],
				['05:00', 2383.43, 2385.42, 2371.23, 2391.82],
				['06:00', 2377.41, 2419.02, 2369.57, 2421.15],
				['07:00', 2425.92, 2428.15, 2417.58, 2440.38],
				['08:00', 2411, 2433.13, 2403.3, 2437.42],
				['09:00', 2432.68, 2434.48, 2427.7, 2441.73],
				['10:00', 2430.69, 2418.53, 2394.22, 2433.89],
				['11:00', 2416.62, 2432.4, 2414.4, 2443.03],
				['12:00', 2441.91, 2421.56, 2415.43, 2444.8],
				['13:00', 2420.26, 2382.91, 2373.53, 2427.07],
				['14:00', 2383.49, 2397.18, 2370.61, 2397.94],
				['15:00', 2378.82, 2325.95, 2309.17, 2378.82],
				['16:00', 2322.94, 2314.16, 2308.76, 2330.88],
				['17:00', 2320.62, 2325.82, 2315.01, 2338.78],
				['18:00', 2313.74, 2293.34, 2289.89, 2340.71],
				['19:00', 2297.77, 2313.22, 2292.03, 2324.63],
				['20:00', 2322.32, 2365.59, 2308.92, 2366.16],
				['21:00', 2364.54, 2359.51, 2330.86, 2369.65],
				['22:00', 2332.08, 2273.4, 2259.25, 2333.54],
				['23:00', 2274.81, 2326.31, 2270.1, 2328.14],
				
				['00:00', 2320.26, 2320.26, 2287.3, 2362.94],
				['01:00', 2300, 2291.3, 2288.26, 2308.38],
				['02:00', 2295.35, 2346.5, 2295.35, 2346.92],
				['03:00', 2347.22, 2358.98, 2337.35, 2363.8],
				['04:00', 2360.75, 2382.48, 2347.89, 2383.76],
				['05:00', 2383.43, 2385.42, 2371.23, 2391.82],
				['06:00', 2377.41, 2419.02, 2369.57, 2421.15],
				['07:00', 2425.92, 2428.15, 2417.58, 2440.38],
				['08:00', 2411, 2433.13, 2403.3, 2437.42],
				['09:00', 2432.68, 2434.48, 2427.7, 2441.73],
				['10:00', 2430.69, 2418.53, 2394.22, 2433.89],
				['11:00', 2416.62, 2432.4, 2414.4, 2443.03],
				['12:00', 2441.91, 2421.56, 2415.43, 2444.8],
				['13:00', 2420.26, 2382.91, 2373.53, 2427.07],
				['14:00', 2383.49, 2397.18, 2370.61, 2397.94],
				['15:00', 2378.82, 2325.95, 2309.17, 2378.82],
				['16:00', 2322.94, 2314.16, 2308.76, 2330.88],
				['17:00', 2320.62, 2325.82, 2315.01, 2338.78],
				['18:00', 2313.74, 2293.34, 2289.89, 2340.71],
				['19:00', 2297.77, 2313.22, 2292.03, 2324.63],
				['20:00', 2322.32, 2365.59, 2308.92, 2366.16],
				['21:00', 2364.54, 2359.51, 2330.86, 2369.65],
				['22:00', 2332.08, 2273.4, 2259.25, 2333.54],
				['23:00', 2274.81, 2326.31, 2270.1, 2328.14],
				
				['00:00', 2320.26, 2320.26, 2287.3, 2362.94],
				['01:00', 2300, 2291.3, 2288.26, 2308.38],
				['02:00', 2295.35, 2346.5, 2295.35, 2346.92],
				['03:00', 2347.22, 2358.98, 2337.35, 2363.8],
				['04:00', 2360.75, 2382.48, 2347.89, 2383.76],
				['05:00', 2383.43, 2385.42, 2371.23, 2391.82],
				['06:00', 2377.41, 2419.02, 2369.57, 2421.15],
				['07:00', 2425.92, 2428.15, 2417.58, 2440.38],
				['08:00', 2411, 2433.13, 2403.3, 2437.42],
				['09:00', 2432.68, 2434.48, 2427.7, 2441.73],
				['10:00', 2430.69, 2418.53, 2394.22, 2433.89],
				['11:00', 2416.62, 2432.4, 2414.4, 2443.03],
				['12:00', 2441.91, 2421.56, 2415.43, 2444.8],
				['13:00', 2420.26, 2382.91, 2373.53, 2427.07],
				['14:00', 2383.49, 2397.18, 2370.61, 2397.94],
				['15:00', 2378.82, 2325.95, 2309.17, 2378.82],
				['16:00', 2322.94, 2314.16, 2308.76, 2330.88],
				['17:00', 2320.62, 2325.82, 2315.01, 2338.78],
				['18:00', 2313.74, 2293.34, 2289.89, 2340.71],
				['19:00', 2297.77, 2313.22, 2292.03, 2324.63],
				['20:00', 2322.32, 2365.59, 2308.92, 2366.16],
				['21:00', 2364.54, 2359.51, 2330.86, 2369.65],
				['22:00', 2332.08, 2273.4, 2259.25, 2333.54],
				['23:00', 2274.81, 2326.31, 2270.1, 2328.14],
				
				['00:00', 2320.26, 2320.26, 2287.3, 2362.94],
				['01:00', 2300, 2291.3, 2288.26, 2308.38],
				['02:00', 2295.35, 2346.5, 2295.35, 2346.92],
				['03:00', 2347.22, 2358.98, 2337.35, 2363.8],
				['04:00', 2360.75, 2382.48, 2347.89, 2383.76],
				['05:00', 2383.43, 2385.42, 2371.23, 2391.82],
				['06:00', 2377.41, 2419.02, 2369.57, 2421.15],
				['07:00', 2425.92, 2428.15, 2417.58, 2440.38],
				['08:00', 2411, 2433.13, 2403.3, 2437.42],
				['09:00', 2432.68, 2434.48, 2427.7, 2441.73],
				['10:00', 2430.69, 2418.53, 2394.22, 2433.89],
				['11:00', 2416.62, 2432.4, 2414.4, 2443.03],
				['12:00', 2441.91, 2421.56, 2415.43, 2444.8],
				['13:00', 2420.26, 2382.91, 2373.53, 2427.07],
				['14:00', 2383.49, 2397.18, 2370.61, 2397.94],
				['15:00', 2378.82, 2325.95, 2309.17, 2378.82],
				['16:00', 2322.94, 2314.16, 2308.76, 2330.88],
				['17:00', 2320.62, 2325.82, 2315.01, 2338.78],
				['18:00', 2313.74, 2293.34, 2289.89, 2340.71],
				['19:00', 2297.77, 2313.22, 2292.03, 2324.63],
				['20:00', 2322.32, 2365.59, 2308.92, 2366.16],
				['21:00', 2364.54, 2359.51, 2330.86, 2369.65],
				['22:00', 2332.08, 2273.4, 2259.25, 2333.54],
				['23:00', 2274.81, 2326.31, 2270.1, 2328.14],
			];
			const categoryData = [];
			const values = [];
			for (var i = 0; i < rawData.length; i++) {
				categoryData.push(rawData[i].splice(0, 1)[0]);
				values.push(rawData[i].map(v=> {return (v - 2000).toFixed(2)}));
			}
      resolve({categoryData, values})
    })
  }
}
